import request from '@/utils/request'


//查询作物类型
export function queryZwlxDict(params) {
    return request({
        url: '/business/insuranceOrder/orderManager/queryZwlxDict',
        method: 'get',
        params
    })
}


//  查询险种列表
export function queryFarmersFileList(params) {
    return request({
        url: '/business/insuranceOrder/orderDetailManager/queryFarmerInfo',
        method: 'get',
        params
    })
}

//  查询农户档案列表
export function getFarmersList(params) {
    return request({
        url: '/business/peasantHousehold/list',
        method: 'get',
        params
    })
}

//  增加农户
export function addFarmerInfo(data) {
    return request({
        url: '/business/peasantHousehold/addData',
        method: 'post',
        data
    })
}

//  更新农户
export function updateFarmerInfo(data) {
    return request({
        url:'/business/peasantHousehold/updateData',
        method:'post',
        data
    })
}

//  删除农户
export function delFarmerInfo(params) {
    return request({
        url:`/business/peasantHousehold/deleteData`,
        method:'delete',
        params
    })
}

//  获取农户详情
export function getFarmerInfoById(params){
    return request({
        url: `/business/peasantHousehold/getDetail`,
        method: 'get',
        params
    })
}

//  获取农户采集信息
export function queryAcquisition(id){
    return request({
        url: `/business/peasantHousehold/queryAcquisition/${id}`,
        method: 'get',

    })
}

//  获取农户历史保单数据
export function queryHistoryOrder(id){
    return request({
        url: `/business/peasantHousehold/queryHistoryOrder/${id}`,
        method: 'get',

    })
}

//  获取农户地块数据
export function queryPlot(id){
    return request({
        url: `/business/peasantHousehold/queryPlot/${id}`,
        method: 'get',

    })
}

